package com.fuhao.api.service;

import javax.servlet.http.HttpServletRequest;

import org.apache.ibatis.annotations.Mapper;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

import com.fuhao.api.entity.UserEntity;
import com.fuhao.base.ResponseBase;

@RequestMapping("/member")
public interface MemberService {
	
	/**
	 * 根据id查询用户信息
	 * @param id
	 * @return
	 */
	@RequestMapping("/findUser")
	ResponseBase findUserById(Long userId);
	@RequestMapping("/reg")
	ResponseBase regUser(@RequestBody UserEntity userEntity);
	//用户登陆
	@RequestMapping("/login")
	ResponseBase login(@RequestBody UserEntity userEntity);
	@RequestMapping("/findByTokenUser")
	ResponseBase findByTokenUser(@RequestParam("token") String token);
	//使用qq的openid查找用户信息
	@RequestMapping("/findByOpenIdUser")
	ResponseBase findByOpenIdUser(@RequestParam("openid") String openid);
	@RequestMapping("/qqLogin")
	ResponseBase qqLogin(@RequestBody UserEntity userEntity);
}
